{template "../Public/header"}
<link rel="stylesheet" type="text/css" href="__PUBLIC__/Css/Home/tao.css" />
<script src="http://a.tbcdn.cn/apps/top/x/sdk.js?t=120525.js"></script>
<script type="text/javascript">
var tb_appkey = '{TAOBAO_LOGIN_APPKEY}';
var gaJsHost = ("https:" == document.location.protocol) ? "https://" : "http://";
gaJsHost += window.location.hostname + '{__ROOT__}' + '/';
var top_session = '{$top_session}';
var timestamp = '{$timestamp}';
var end_time = '{$end_time}';
var seller_nick = '{$shop.nick}';
TOP.init({
      appKey : tb_appkey,
      channelUrl : gaJsHost + 'channel.html'
});//每个页面只需配置一次系统参数
</script>
{template "../Public/nav"}
<div class="tao-wrap">
<div class="lt">
<div  class="tao-show">
<h1>{$detail.title}</h1>
  <dl>
  <dt><A class="lazy-img-loader" href="{echo reUrl('Tao/shop?id='.$shop[id])}"><IMG src="{echo tao_shop_logo($shop['pic_path'])}"  alt="{$shop.title}优惠券" ></A></dt>
<dd style="width:300px;">
<p>优惠金额：<!--{if $detail['c_type']==1}-->满<em>{$detail.money_max}</em>减<em>{$detail.money_reduce}</em><!--{else}--><em>{$detail.money_amount}</em>元代金券<!--{/if}--></p>
<p>领取限制：{$detail['data']['fetch_limit']}</p>
<p>剩余时间：<!--{if $detail['expiry_type']==1}--><!--{if $detail['expiry']==0}-->已结束<!--{else}-->还剩 <em><!--{if $detail['expiry']>$_CFG['max_left_days']}-->{$_CFG['max_left_days']}<!--{else}-->{$detail.expiry}<!--{/if}--></em> 天<!--{/if}--><!--{else}-->长期有效<!--{/if}--></p>
</dd>
<dd style="width:200px;">
<p>售价：<!--{if $detail['price_type']==1}-->免费<!--{elseif $detail['price_type']==2}--><em>{$detail.price}</em>元<!--{elseif $detail['price_type']==3}--><em>{$detail.price}</em>积分<!--{/if}--></p>
<p>已领取：<em>{$detail.fetched_amount}</em> 张</p>
<p><a href="{echo reUrl('Tao/shop?id='.$item[id])}" title="{$shop.title}优惠券"><img src="__PUBLIC__/Images/Taobao/show-go.jpg" width="91" height="38" /></a><span><a href="#how2use" title="如何使用">如何使用?</a></span></p>
</dd>
</dl>


</div>
<!--{if $shop['desc']}-->
<div class="tao-css4">
  <dl><dt>商家介绍</dt></dl>
 <ul><li>
<p>{$shop.desc}</p>
</li></ul>
</div>
<!--{/if}-->
<!--{if $detail['data']['directions']}-->
<div class="tao-css4">
  <dl><dt>本券说明</dt></dl>
 <ul><li>
{$detail['data']['directions']}
</li></ul>
</div>
<!--{/if}-->
<div class="tao-css4" id="how2use">
  <dl><dt>如何使用</dt></dl>
 <ul><li>
   <img src="__PUBLIC__/Images/Taobao/coupon_how_to1.jpg" width="617" height="169" />
   <img src="__PUBLIC__/Images/Taobao/coupon_how_to2.jpg" width="617" height="169" />
   <img src="__PUBLIC__/Images/Taobao/coupon_how_to3.jpg" width="617" height="169" /> </li>
 </ul>
</div>
</div>
<div class="ri">
<div class="tao-css5">
  <dl><dt>店铺信息</dt></dl>
<ul>
  <li>
<h4>商家名称：<a href="{echo reUrl('Tao/shop?id='.$shop[id])}" title="{$shop.title}优惠券">{$shop.title}</a></h4>
<h4>店铺信誉：<span class="credit credit_{$shop.level}"></span></h4>
<h4>描述属实：<span class="score score_{echo floor(($shop['item_score']/5)*10)}">{$shop.item_score}分</span></h4>
<h4>服务态度：<span class="score score_{echo floor(($shop['service_score']/5)*10)}">{$shop.service_score}分</span></h4>
<h4>发货速度：<span class="score score_{echo floor(($shop['delivery_score']/5)*10)}">{$shop.delivery_score}分</span></h4>
  </li>
  <li><a href="{echo reUrl('Tao/out?id='.$shop[id])}"  title="{$shop.title}优惠券" rel="nofollow" target="_blank"><img src="__PUBLIC__/Images/Taobao/shop-buy.jpg" width="88" height="24"  alt=""/></a></li>
</ul>
</div>
<!--{if $others}-->
<div class="shopAllCoupons3">
<dl><dt>{$shop.title}其他优惠券</dt></dl>
<ul>
<!--{loop $others $item}-->
<li><a title="{if $item['title']}{$item.title}{else}{$item.s_title}{if $item['c_type']==1}满{$item.money_max}减{$item.money_reduce}元优惠券{else}{$item.money_amount}元代金券{/if}{/if}" href="{echo reUrl('Tao/show?id='.$item[c_id])}">{if $item['title']}<span>{$item.title}</span>{else}<span>{if $item['c_type']==1}满<span class="condition"><EM class="r-num">{$item.money_max}</EM></span>减<span class="condition"><EM class="r-num">{$item.money_reduce}</EM></span>元优惠券{else}<span>{$item.money_amount}元代金券</span>{/if}</span>{/if}<span class="btn-holder"><!--{if $item['expiry_type']==1 && $item['expiry']<=$nowtime}-->
  <span class="btn1">已过期</span>
  <!--{else}-->
  <span class="btn">去领取</span>
  <!--{/if}--></span><span class="cutter"></span></a>
</li>
<!--{/loop}-->
</ul>
</div>
<!--{/if}-->
  <div class="tao-css3">
  <dl><dt>掌柜热卖</dt></dl>
<ol>
<!--{eval $items=tao_shop_recommend_items($shop['seller_id']);}-->
<!--{loop $items $item}-->
<li><a href="__ROOT__/index.php?m={MODULE_NAME}&a=out_item&item_id={$item.item_id}&click_url={echo urlencode($item['click_url'])}&item_url={echo urlencode($item['item_url'])}"  title="{$item.item_name}优惠券" rel="nofollow" target="_blank"><IMG src="{$item.item_pictrue}"  alt="{$item.item_name}优惠券" >{$item.item_name}
<span>￥{$item.item_price}</span></a></li>
<!--{/loop}-->
</ol>
</div>

</div>
</div>
<script type="text/javascript">
TOP.api('rest','get',{
       method:'taobao.promotion.coupon.buyer.search',
       session:top_session,
       timestamp:timestamp,
       status:'unused',
	   end_time:end_time,
	   seller_nick:seller_nick,
	   page_size:20,
	   page_no:1
},function(resp){
        if(resp.buyer_coupon_details){
                  alert('success!');
         }else{
                  alert('failure!');
} });
</script>
{template "../Public/footer"}